Class pyglet.window.Display

A display device supporting one or more screens.

Use Platform.get_display or Platform.get_default_display to obtain an instance of this class. Use a display to obtain Screen instances.

Methods

  __init__(self)
list of Screen get_screens(self)
Get the available screens.
Screen get_default_screen(self)
Get the default screen as specified by the user's operating system preferences.
sequence of Window get_windows(self)
Get the windows currently attached to this display.

Method Details

get_screens

get_screens(self)

Get the available screens.

A typical multi-monitor workstation comprises one Display with multiple Screen s. This method returns a list of screens which can be enumerated to select one for full-screen display.

For the purposes of creating an OpenGL config, the default screen will suffice.

Returns: list of Screen